package Node;

public class NodeDescriptor {
	
	static NodeDescriptor 
	
	protected int nodeServerPort;
	protected int datagramMaximumSize;
	
private static Configurator sharedInstance = null; 
	
	protected String configFile;
	
	// I parametri vengono prelevati da un file XML (Key=Value/s)
	
	
	public Configurator()
	{
		super();
	}
	
	public String getConfigFile(){
		return this.configFile;
	}
	
	public void setConfigFile(String externalFile){
		configFile = externalFile;
	}
	
	public int getNodeServerPort()
	{
		return this.nodeServerPort;
	}
	
	public void setNodeServerPort(int newPort)
	{
		this.nodeServerPort = newPort;
	}
	
	public int getDatagramMaximumSize()
	{
		return this.datagramMaximumSize;
	}
	
	public void setDatagramMaximumSize(int newSize)
	{
		this.datagramMaximumSize = newSize;
	}
	
	public static Configurator sharedConfigurator()
	{
		if(sharedInstance == null) 
			sharedInstance = new Configurator();
		return sharedInstance;
	}
}
